#pragma once

#include "ClassData.h"

class CCharacterTable
{
public:
	CCharacterTable();

	CClassData & AddClass(string name, string type, int lineIndex);
	CClassData & GetClass(string classVarName);
	int HasClass(string classVarName);

	CCharData & AddClassLocalChar(string ownerVarName, string name, string type, int lineIndex);
	CCharData & GetClassLocalVar(string classOwnerVarName, string name);
	int HasClassLocalVar(string ownerVarName, string name);

	CCharData & AddMethodLocalChar(string classOwnerVarName, string methodOwnerName, string name, string type, int lineIndex);
	CCharData & GetMethodLocalVar(string classOwnerVarName, string methodOwnerName, string name);
	int HasMethodLocalVar(string classOwnerVarName, string methodOwnerName, string name);

	CMethodData & AddMethod(string classOwnerVarName, string name, int lineIndex);
	CMethodData & GetMethod(string classOwnerVarName, string name);
	int HasMethod(string classOwnerVarName, string name);

private:
	vector<CClassData> m_classes;
};